<?php
/*
 * @version :  2013-5-9
 * @project :  account-system
 * @Author  :  Allen
 * @e-mail  :  shulei@maszy.cn
 */
require_once (dirname(__FILE__)."/../config/config.php");

 $content = getXml();
 outPutXml($content);
function getXml(){
	$content = "";
	if(isset($_REQUEST['mac'])){
		$content.= "<result>\n";
		$content.= "<urllist>\n";
		
		$content.= "<url>http://v.youku.com/player/*</url>\n";
		$content.= "<url>http://www.tudou.com/a/*</url>\n";
		$content.= "<url>http://www.tudou.com/v/*</url>\n";
		$content.= "<url>http://s.plcloud.music.qq.com/*</url>\n";
		$content.= "<url>http://web-play.pptv.com/*</url>\n";
		$content.= "<url>http://mobilefeedback.kugou.com/*</url>\n";
		$content.= "<url>http://210.129.145.150/*</url>\n";
		$content.= "</urllist>\n";
//		$sql="select * from zy_equipment  where MacAddress='".$_REQUEST['mac']."'";
//		$rs = mysql_query($sql);
//		$row = mysql_fetch_array($rs);
//		
//		$sqluser = "select * from zy_routersettings where user_id='".$row['updater']."'";
//		$rsult = mysql_query($sqluser);
//		$content.= "<ssidlist>\n";
//		while($rows = mysql_fetch_array($rsult)){
//			$content.= "<ssid>\n";
//			$content.= "<id>".$rows['id']."</id>\n";
//			$content.= "<name>".$rows['name']."</name>\n";
//			$content.= "<password>".$rows['password']."</password>\n";
//			$content.= "<priority>".$rows['priority']."</priority>\n";
//			$content.= "<speedlimit>".$rows['speedlimit']."</speedlimit>\n";
//			$content.= "</ssid>\n";
//		}
//		$content.= "</ssidlist>\n";
		$content.= "</result>\n";
	}
	return $content;
}




function outPutXml($content) {
	header("Content-type:text/xml");
	echo "<?xml version=\"1.0\" encoding=\"UTF-8\" standalone=\"yes\" ?>\n";
	echo "<netcuberesult>\n";
	echo $content;
	echo "</netcuberesult>";
	die();
}
?>